#ifndef _OI_PLSCANNERDLL_PAGEABSTRACT_HPP_
#define _OI_PLSCANNERDLL_PAGEABSTRACT_HPP_

#include "PLScannerCore/OiPLScannerCore.hpp"
#include "PLScannerCore/Config/OiProductParams.hpp"
#include "PLScannerCore/OiPLScannerWorker.hpp"

namespace Oi
{
    namespace PLScannerDll
    {
        class PageAbstract : public QWidget
        {
            Q_OBJECT

        public:
            PageAbstract(QWidget * parent = nullptr);

        public:
            virtual void setParams(const PLScannerCore::ProductParams& params) = 0;
            virtual int setResult(const PLScannerCore::WorkResult::Result& result) = 0;
            virtual void setRun(bool flag) = 0;
            virtual void toCurrent() = 0;

        public:
            virtual void updatePermission();           
            virtual void addResult(const PLScannerCore::WorkResult::Result& result);
            virtual void run(bool flag);

        protected:
            virtual void showEvent(QShowEvent *event);
            virtual void hideEvent(QHideEvent *event);

        private:
            OI_DECLARE_IMPL(PageAbstract);
            OI_DISABLE_COPY(PageAbstract);

        };
    }
}
#endif
